package com.haiheng.videodoorbell.widget.webview

import android.content.Intent
import com.tencent.smtt.sdk.WebView

/**
 *
 * @Des:
 * @Author: hwz
 * @Date:2022/3/25 0025
 * @Version: 1.0
 */
interface IX5WebPageView {
    /**
     * 显示webview
     */
    fun showWebView()

    /**
     * 隐藏webview
     */
    fun hindWebView()

    /**
     * 进度条变化时调用
     *
     * @param newProgress 进度0-100
     */
    fun startProgress(newProgress: Int)

    /**
     * 上传图片打开文件夹
     */
    fun startFileChooserForResult(intent: Intent?, requestCode: Int)


    /**
     * 页面加载结束，添加js监听等
     */
    fun onPageFinished(view: WebView?, url: String?)

    /**
     * 是否处理打开三方app
     * @param url
     */
    fun isOpenThirdApp(url: String?): Boolean


    fun onJsFunctionCalled(funName:String,key:String?,values:String?)

}